package com.example.logisticsingle.constants;


/**
 * 单点登录配置信息
 *
 */
public class Config {
    /**
     * sso sessionid, between browser and sso-server (web + token client)
     */
    public static final String SSO_SESSIONID = "sso_sessionid";

    public static final String ACCESS_TOKEN = "access_token";
    /**
     * redirect url (web client)
     */
    public static final String REDIRECT_URL = "redirect_url";
    /**
     * sso user, request attribute (web client)
     */
    public static final String SSO_USER = "sso_user";
    /**
     * sso server address (web + token client)
     */
    public static final String SSO_SERVER = "sso_server";
    /**
     * login url, server relative path (web client)
     */
    public static final String SSO_LOGIN = "/login";
    /**
     * logout url, server relative path (web client)
     */
    public static final String SSO_LOGOUT = "/logout";
    /**
     * logout path, client relatice path
     */
    public static final String SSO_LOGOUT_PATH = "SSO_LOGOUT_PATH";
    /**
     * excluded paths, client relatice path, include path can be set by "filter-mapping"
     */
    public static final String SSO_EXCLUDED_PATHS = "SSO_EXCLUDED_PATHS";
    /**
     * Token过期时间
     */
    public static final String TOKEN_EXPIRE_TIME = "token_expire";
    /**
     *  记住我参数
     */
    public static final String REMEMBERME_NAME = "remember_me";
    /**
     * 请求类型
     */
    public static final String REQUEST_TYPE = "Request-Type";
    /**
     * 请求代理参数
     */
    public static final String REQUEST_USER_AGENT = "Request-User-Agent";
    /**
     * 请求IP
     */
    public static final String REQUEST_IP = "Request-IP";
    /**
     * 5天(以毫秒ms计)
     */
    public static final long EXPIRATION_TIME = 432000000L;
    /**
     * JWT密码
     */
    public static final String SECRET = "CodeSheepSecret";
    /**
     * Token前缀
     */
    public static final String TOKEN_PREFIX = "Bearer";
    /**
     * 存放Token的Header Key
     */
    public static final String DEFAULT_TOKEN_HEADER_STRING = "Authorization";

    /**
     * Web请求登录
     */
    public static final int REQUEST_TYPE_WEB = 0;
    /**
     * Rest请求登录
     */
    public static final int REQUEST_TYPE_REST = 1;


}
